<template>
	<view>
		<view class="head">
			<image src="../../static/images/arrow_left.png" mode="" @click="go"></image>
			<view class="">添加账号</view>
			<view class="f32" @click="seave">保存</view>
		</view>
		<view class="wen">
			金融机构可填写银行名称、支付宝等机构名称，如中国 中国银行、支付宝、微信；户名填写对应的账户名称， 如张三；账户填写银行号或微信支付宝号，如6225 999 9 3333 4444
		</view>
		<view class="heads">
			<view class="box-l">金融机构</view>
			<view class="box-r"><input type="text" placeholder="请输入银行或其他机构名称" v-model="organization" /></view>
		</view>
		<view class="heads">
			<view class="box-l">用户</view>
			<view class="box-r"><input type="text" placeholder="请输入账号名称" v-model="account_name" /></view>
		</view>
		<view class="heads">
			<view class="box-l">账号</view>
			<view class="box-r"><input type="text" placeholder="请输入账号" v-model="account_no" /></view>
		</view>
	</view>
</template>

<script>
export default {
	data() {
		return {
			act: 'add',
			organization: '',
			account_name: '',
			account_no: ''
		};
	},
	methods: {
		seave() {
			this.$ajax('api/v1.shop/receiveAccount', {
				act: 'add',
				organization: this.organization,
				account_name: this.account_name,
				account_no: this.account_no
			})
				.then(res => {
					uni.navigateTo({
						url: 'paymentAccount'
					});
				})
				.catch(res => {
					console.log(Error);
				});
		},
		go(){
			uni.navigateTo({
			    url: 'generalSettings'
			});
		}
	}
};
</script>

<style lang="scss">
page {
	background-color: #f7f4f8;
}
.head {
	height: 88rpx;
	line-height: 88rpx;
	background-color: #249af6;
	color: #ffffff;
	display: flex;
	justify-content: space-between;
	padding: 0 30rpx;
	font-size: 36rpx;
	font-family: PingFang SC;
	font-weight: 500;
	image {
		width: 22rpx;
		height: 39rpx;
		margin-top: 25rpx;
	}
}
.wen {
	line-height: 42rpx;
	font-size: 28rpx;
	font-family: PingFang SC;
	font-weight: 500;
	color: rgba(102, 102, 102, 1);
	padding: 30rpx;
	box-sizing: border-box;
}
.heads {
	height: 110rpx;
	line-height: 110rpx;
	background-color: #ffffff;
	display: flex;
	justify-content: space-between;
	padding: 0 30rpx;
	font-size: 32rpx;
	font-family: PingFang SC;
	font-weight: 500;
	position: relative;
	border-bottom: 2rpx solid #eeeeee;
	image {
		width: 18rpx;
		height: 33rpx;
		vertical-align: middle;
		margin-left: 20rpx;
	}
	.box-r {
		.box-l {
			position: absolute;
			left: 0;
		}
		input {
			width: 100%;
			text-align: right;
			height: 100%;
			overflow: hidden;
			padding-left: 100rpx;
			box-sizing: border-box;
		}
		.bx {
			position: absolute;
			right: 100rpx;
		}
		font-size: 32rpx;
		font-family: PingFang SC;
		font-weight: 500;
		color: rgba(102, 102, 102, 1);
	}
}
</style>
